package com.company.nuwa.common.domain;

import lombok.Data;

import java.util.ArrayList;
import java.util.List;

/**
 * <p>树节点</p>
 *
 * @author Lionel Lee
 * @version 1.0: TreeNode.java
 * @date 2021/5/25 1:03 下午
 */

@Data
public class TreeNodeDTO {

    protected Long value;
    protected Long parentId;
    protected String text;
    protected List<TreeNodeDTO> children = new ArrayList<>();

    public void add(TreeNodeDTO node) {
        children.add(node);
    }
}
